1. Field of the Invention
The present invention relates generally to communications over packet networks. More particularly, the present invention relates to the configuration of gateway devices for controlling data flow while communicating over a packet network, such as the Internet, utilizing the Internet Protocol (“IP”).
2. Related Art
In recent years, packet-based networks, such as the Internet, have begun to replace the traditional switched telephone networks for transportation of voice and data. For example, with the emergence of voice over IP (“VoIP”), telephone conversations may now be captured, packetized and transported over the Internet. In a conventional VoIP system, telephone conversations or analog voice may be transported over the local loop or the public switch telephone network (“PSTN”) to the central office (“CO”). From the CO, the analog voice is transported to a gateway device at the edge of the packet-based network. The gateway device converts the analog voice or speech to packetized data using a codec (coder/decoder), according to one of various existing protocols, such as G.729, G.711, G.723.1, etc. Next, the packetized data is transmitted over the Internet using the Internet Protocol for reception by a remote gateway device and conversion back to analog voice.
Today, many have diverted their focus to using the existing packet-based network and gateway devices, which have been designed to support the transportation of analog voice or speech over IP, to further support modem communication over IP, or as it is referred to in the industry, Modem over Internet Protocol (“MoIP”). FIG. 1 illustrates a block diagram of a conventional communication model for MoIP based on a packet-based network, such as the Internet. As shown, communication model 100 includes first client communication device 110 in communication with first gateway communication device 120 over PSTN providing transmit and receive channels 112 and 114. Communication model 100 further includes second client communication device 150 in communication with second gateway communication device 140 over PSTN providing transmit and receive channels 144 and 142. Communication model 100 enables communications between first gateway communication device 120 and second gateway communication device 140 via a packet network 130 utilizing the Internet Protocol. The Internet Protocol implements the network layer (layer 3) of a network protocol, which contains a network address and is used to route a message to a different network or subnetwork. The Internet Protocol further accepts packets from the layer 4 transport protocol, such as Transmission Control Protocol (“TCP”) or User Data Protocol (“UDP”), and adds its own header and delivers the data to the layer 2 data link protocol. TCP provides transport functions, which ensures that the total amount of bytes sent is received correctly at the other end. UDP, which is part of the TCP/IP suite, is an alternate transport that does not guarantee delivery. It is widely used for real-time voice and video transmissions where erroneous packets are not retransmitted. Another transport protocol recently advanced for use with MoIP is Simple Packet Relay Transport (“SPRT”) which provides a plurality of communication channels, some of which are defined as “unreliable” (i.e., does not guarantee delivery) and others of which are defined as “reliable” (i.e., guarantees delivery).
For purposes of MoIP, communication devices 110, 120, 140 and 150 are capable of performing modem functions. The term modem stands for modulator-demodulator (i.e. digital-to-analog/analog-to-digital converter). Modem is a device that is capable of adapting a terminal or computer to an analog telephone line by converting digital pulses to audio frequencies and vice versa. Modems may support a variety of data modulation standards, such as ITU (International Telecommunications Union) standards: V.22bis, V.34, V.90 or V.92, etc. Communication devices 110, 120, 140 and 150 may also be cable or DSL modems, which are all digital and technically not modems, but referred to as modems in the industry. Typically, modems have built-in error correction, such as MNP2-4 or LAPM (or V.42) and data compression, such as MNP5, V.42bis or V.44. Modems are also capable of supporting various voice and facsimile standards.
Conventionally, the communication process for MoIP begins when first client modem ((“M1”) or first client communication device 110) calls first gateway modem ((“G1”) or first gateway communication device 120). As a result, G1 calls second gateway modem ((“G2”) or second gateway communication device 140), and G2 in turn calls second client modem ((“M2”) or second client communication device 150). In order to support VoIP in their default mode of operation, typically, G1 and G2 communicate in voice mode and are configured to use a compressed voice protocol, such as the ITU standard G.723.1. However, when M2 answers the incoming call from G2, M2 generates an answer tone, e.g. 2100 Hz, that causes G1 and G2 to switch to an uncompressed voice protocol, such as an ITU standard G.711, which provides toll quality audio at 64 Kbps using either A-Law or mu-Law pulse code modulation methods. This uncompressed digital format is used in order to allow easy connections to legacy telephone networks. By switching to G.711, the tones generated by M2 may propagate through G1 and G2 in a more intact manner in order to reach M1 at the other side.
One existing method provides for maintaining G1 and G2 in G.711 or modem pass through mode, such that M1 and M2 are able to handshake over packet network 130 and transfer data using G.711 packets using the Internet Protocol. However, such solution suffers from many problems, such as packet loss, jitter and delay, which cannot be tolerated by high-speed modems. To overcome such problems, modem connections are terminated locally such that M1 and G1 handshake and make a connection locally to establish a M1-G1 connection link. Similarly, M2 and G2 handshake and make a connection locally to establish a M2-G2 connection link. After the connection links between M1-G1 and M2-G2 are established, data transmitted by M1 is relayed by G1 to G2 over packet network 130 for transmission to M2. Likewise, data transmitted by M2 is relayed by G2 to G1 over packet network 130 for transmission to M1.
Depending on the type of connection link established between M1 and G1 on the one hand and M2 and G2 on the other, certain problems may arise that can affect the modem relay operation. For example, if both the M1-G1 connection link and the M2-G2 connection link are established with error correction, then the connection between G1 and G2 are generally configured with error correction, and relay of data between M1 and M2 is generally not problematic. By way of illustration, consider the case where the connection links between M1-G1 and M2-G2 are established with an error correction protocol that provides flow control, such as V.42 or MNP4. In this case, the G1-G2 connection is configured using a reliable transport. When data is transmitted by M1 to G1 using the error correction protocol, the data is received into G1's data buffer. Data from G1's data buffer is then transferred to G1's error correction buffer; data from the G1's error correction buffer is then transmitted to G2 over the reliable transport. In a similar way, data transmitted by G1 is received into G2's data buffer. Data from G2's data buffer is then transferred to G2's error correction buffer; data from the G2's error correction buffer is then transmitted to M2 using the error correction protocol. Since the G2-M2 link provides error correction, G2 maintains data transmitted to M2 in its error correction buffer until an acknowledgement from M2 confirming receipt of the transferred data. Once acknowledged, data is removed from the error correction buffer, and additional data from the data buffer is transferred to the error correction buffer for transmission, thus clearing the data buffer to receive additional data. On the other hand, if an acknowledgement is not received, the data remains in G2's error correction buffer and is retransmitted by G2 to M2 until acknowledgement from M2 is received. In such situations where retransmission by G2 is required, G2's data buffer continues to receive data transmitted by G1 from M1. Since G2's error correction buffer is not being cleared during retransmission, G2's data buffer is likewise not being cleared during retransmission and continues to accumulate data transmitted from G1. When a certain threshold level in G2's data buffer is reached, G2 transmits a request or notification to G1 to stop data flow (e.g., a “flow off” request). G1 receives G2's stop data flow request, and stops transferring data from its error correction buffer to G2. During this stop data transfer phase, G1's error correction buffer is not being cleared, and therefore G1's data buffer continues to accumulate data received from M1. When a certain threshold level in G1's data buffer is reached, G1 transmits a request or notification to M1 to stop data flow (e.g., a receiver not ready (RNR)). M1 receives the stop data flow request and stops the data transfer to G1. Once G2 is able to successfully transmit to M1, G2's error correction buffer is cleared and replaced with data from G2's data buffer. After G2's data buffer falls below a certain threshold, G2 transmits a request or notification to G1 to resume data flow (e.g., a “flow on” command). G1 receives G2's resume data flow request, and resumes data transfer from its error correction buffer, resulting in G1's error correction buffer and data buffer being cleared. After G1's data buffer falls below a certain threshold, G1 transmits a request or notification to M1 to resume data flow (e.g., a receive reader (RR)). M1 receives G1's resume data flow request, and resumes data transfer to G1. As illustrated in the above sequence, the ability of G2 and G1 to stop the flow of transferred data from a sender prevents buffer overflow and loss of data for transmission from M1 to M2. The same level of buffer overflow and data loss protection is provided for data transmission from M2 to M1.
However, where one of the connection links between M1-G1 and M2-G2 are established without error correction, modem relay operation and performance can present problems. For example, in the case where the M1-G1 connection link is established without error correction and the M2-G2 connection link is established with error correction (e.g., V.42 or MNP4), G1 and G2 may be configured to communicate over packet network 130 using error correction (such as a reliable transport). This configuration allows G2 to control the flow of data transmitted by G1 to G2 (e.g., by communicating a stop data flow request or notification to avoid data buffer overflow). In response to this command, G1 stops data transfer to G2. In this situation, G1 is unable to clear its error-correction buffer, and therefore its data buffer continues to accumulate data received from M1. However, data transmitted by M1 to G1 cannot be flow controlled by G1 (since G1 is not able to communicate a stop data flow request or notification to M1), because the M1-G1 connection link is established without error correction. As a result, G1's data buffer becomes susceptible to overflow, which results in data loss between the M1-G1 link.
In order to remedy this problem, one proposal has been to configure G1 and G2 to use an unreliable transport protocol or channel in both directions if either one of the G1-M1 and G2-M2 connection links is established without error correction or flow control capability. However, such proposal introduces a significant drawback in that an unreliable protocol makes data transfer over packet network 130 extremely susceptible to network impairments of packet network 130, such as packet loss, jitter and delay, which will still result in loss of data in both directions, i.e. from M1 to M2 and from M2 to M1. Various embodiments of the present invention, as disclosed below, describe methods and devices, which can remedy the shortcomings of such proposal.